package com.haowu.product.domain.bo;

import com.haowu.common.core.validate.AddGroup;
import com.haowu.common.core.validate.EditGroup;
import com.haowu.common.core.web.domain.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
 * 好务服务项目业务对象
 *
 * @author lky
 * @date 2023-02-23
 */

@Data
@EqualsAndHashCode(callSuper = true)
public class HwServiceBo extends BaseEntity {

    /**
     * 主键id
     */
    @NotNull(message = "主键id不能为空", groups = { EditGroup.class })
    private Long id;

    /**
     * 一级分类
     */
    @NotNull(message = "一级分类不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long categoryId;

    /**
     * 城市id
     */
    @NotNull(message = "城市id不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long cityId;

    /**
     * 服务编号
     */
    @NotBlank(message = "服务编号不能为空", groups = { AddGroup.class, EditGroup.class })
    private String serviceCode;

    /**
     * 服务名称
     */
    @NotBlank(message = "服务名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String serviceName;

    /**
     * 描述
     */
    @NotBlank(message = "描述不能为空", groups = { AddGroup.class, EditGroup.class })
    private String describes;

    /**
     * 封面图
     */
    @NotBlank(message = "封面图不能为空", groups = { AddGroup.class, EditGroup.class })
    private String coverPicture;

    /**
     * 图文详情
     */
    @NotBlank(message = "图文详情不能为空", groups = { AddGroup.class, EditGroup.class })
    private String serviceDetails;

    /**
     * 单次服务时长
     */
    @NotNull(message = "单次服务时长不能为空", groups = { AddGroup.class, EditGroup.class })
    private BigDecimal serviceDuration;

    /**
     * 销量
     */
    @NotNull(message = "销量不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long saleNumber;

    /**
     * 浏览次数
     */
    @NotNull(message = "浏览次数不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long browseNumber;

    /**
     * 分享人数
     */
    @NotNull(message = "分享人数不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long shareNumber;

    /**
     * 状态 0上架 1下架
     */
    @NotBlank(message = "状态 0上架 1下架不能为空", groups = { AddGroup.class, EditGroup.class })
    private String serviceStatus;

    /**
     * 推荐 0不推荐 1推荐
     */
    @NotBlank(message = "推荐 0不推荐 1推荐不能为空", groups = { AddGroup.class, EditGroup.class })
    private String recommended;

    /**
     * 是否参与活动 0不参与 1参与
     */
    @NotBlank(message = "是否参与活动 0不参与 1参与不能为空", groups = { AddGroup.class, EditGroup.class })
    private String isEvent;

    /**
     * 是否删除 0否1是
     */
    @NotNull(message = "是否删除 0否1是不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer isDelete;

    /**
     * 服务次数
     */
    @NotNull(message = "服务次数不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long serviceNumber;

    /**
     * 备注
     */
    @NotBlank(message = "备注不能为空", groups = { AddGroup.class, EditGroup.class })
    private String remark;

    /**
     * 好评率
     */
    @NotNull(message = "好评率不能为空", groups = { AddGroup.class, EditGroup.class })
    private BigDecimal praiseRate;

    /**
     * 排序
     */
    @NotNull(message = "排序不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer sort;


}
